package ptaPartTwo;

import java.util.*;

public class FiveFour {
	
	public static void main(String[] args) {
		Scanner input=new Scanner(System.in);
        while(input.hasNextInt()){
        	String str;
	        int n=input.nextInt();
	        String[][] str1=new String[n][];
	        for (int i = 0; i < n; i++) {
	        	str1[i]=new String[i+1];
				for (int j = 0; j < i+1;j++){
					str=String.format("%d*%d=%d",i+1,j+1,(i+1)*(j+1));
					if(j==i)
						System.out.printf("%s",str);
					else
						System.out.printf("%-7s",str);
					str1[i][j]=new String(str);
				}
				System.out.println("");
			}
	        System.out.println(Arrays.deepToString(str1));
		
	}

	}
}
